package com.rocky.project.service;

import java.io.Serializable;
import java.util.Collection;

import com.rocky.project.util.Result;

public class ProjectBaseServiceImpl extends BaseServiceImpl implements
		ProjectBaseService {

	public Result executeHqlNoParam(String querySql, Result oldResult) {	
		return this.executeHqlNoParam(querySql, oldResult.getPage());
	}

	public int executeHqlNoParam4Count(String querySql) {		
		return this.getCountHqlNoParam(querySql);
	}

	public Result executeHqlWithParam(String querySql, Object[] values,
			Result oldResult) {		
		return this.executeHqlWithParam(querySql, values, oldResult.getPage());
	}

	public int executeHqlWithParam4Count(String querySql, Object[] values) {		
		return this.getCountHqlWithParam(querySql, values);
	}

	public Object read(Class cls, Serializable id) {		
		return this.get(cls, id);
	}

	public Collection readAll(Class entityClass) {	
		return this.loadAll(entityClass);
	}

}
